#include<stdio.h>
int main()
{
	int n;
	double factorial =1;
	scanf("%d",&n);
	for(int i=1;i<=n;i++) {
		factorial *=i;
		printf("%-4d%-20.0lf\n",i,factorial );
	}
	
	return 0;
}

